package models

import (
	"github.com/goravel/framework/database/orm"
	"time"
)

type UserModel struct {
	orm.Model
	Username string    `gorm:"column:username;unique;comment:用户名" json:"username"`
	Password string    `gorm:"column:password;comment:密码" json:"-"`
	Status   int8      `gorm:"column:status;comment:状态" json:"status"`
	LoginAt  time.Time `gorm:"column:login_at" json:"login_at"`
	LoginIP  string    `gorm:"column:login_ip" json:"login_ip"`
}

func (receiver *UserModel) TableName() string {
	return "go_user"
}
